package com.woniuxy.depot.service.impl;

import com.woniuxy.depot.mapper.DepotOutStockItemMapper;
import com.woniuxy.depot.model.entity.DepotOutStockItem;
import com.woniuxy.depot.service.DepotOutStockItemService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class DepotOutStockItemServiceImpl implements DepotOutStockItemService {
    @Resource
    private DepotOutStockItemMapper itemMapper;
    @Override
    public List<Integer> getOutStockIdsByCode(String code) {
        return itemMapper.getOutStockIdsByCode(code);
    }

    @Override
    public void insert(List<DepotOutStockItem> items) {
        for (DepotOutStockItem item:items) {
            itemMapper.insert(item);
        }
    }
}
